#pragma once
#include "Connection.h"
#include "boost/unordered_map.hpp"

class ConnectionMng {
public:
    static ConnectionMng &GetInstance();

    ConnectionMng(const ConnectionMng &) = delete;

    ConnectionMng &operator =(const ConnectionMng &) = delete;

    void AddConnection(const std::shared_ptr<Connection> &con_ptr);

    void RmvConnection(const std::string &id);

private:
    ConnectionMng();

    boost::unordered_map<std::string, std::shared_ptr<Connection> > _map_cons;
};
